import request from '@/utils/request'

// 查询承包商信息列表
export function listContractor(query) {
  return request({
    url: '/system/contractor/list',
    method: 'get',
    params: query
  })
}

// 查询承包商信息详细
export function getContractor(id) {
  return request({
    url: '/system/contractor/' + id,
    method: 'get'
  })
}

// 新增承包商信息
export function addContractor(data) {
  return request({
    url: '/system/contractor',
    method: 'post',
    data: data
  })
}

// 修改承包商信息
export function updateContractor(data) {
  return request({
    url: '/system/contractor',
    method: 'put',
    data: data
  })
}

// 删除承包商信息
export function delContractor(id) {
  return request({
    url: '/system/contractor/' + id,
    method: 'delete'
  })
}
